<?php
	$json = array('error' => $error);
	if(!empty($data)){
		$json['data'] = $data;
		if(!empty($page))
			$json['page'] = $page;
		if(!empty($limit))
			$json['limit'] = $limit;		
	}
	echo json_encode($json);
?>